From: Roger Pau Monne Date: Tue, 26 Apr 2016 10:25:28 +0000 (+0200) Subject: tools/python: corrently use LDFLAGS and CFLAGS X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~1228 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=dbed24c7c4cfcdf5db9582a7b8bc74a2a48d4054;p=xen.git tools/python: corrently use LDFLAGS and CFLAGS It is incorrect to add the LDFLAGS to the CFLAGS, and some compilers will error out if linker flags are passed when creating object files. Fix this by properly passing CFLAGS and LDFLAGS, instead of putting everything in CFLAGS. Signed-off-by: Roger Pau Monné Reviewed-by: Doug Goldstein Acked-by: Wei Liu Release-acked-by: Wei Liu --- diff --git a/tools/python/Makefile b/tools/python/Makefile index 23635374c1..da08f46fb8 100644 --- a/tools/python/Makefile +++ b/tools/python/Makefile @@ -4,7 +4,8 @@ include $(XEN_ROOT)/tools/Rules.mk .PHONY: all all: build -PY_CFLAGS = $(CFLAGS) $(PY_NOOPT_CFLAGS) $(LDFLAGS) $(APPEND_LDFLAGS) +PY_CFLAGS = $(CFLAGS) $(PY_NOOPT_CFLAGS) +PY_LDFLAGS = $(LDFLAGS) $(APPEND_LDFLAGS) .PHONY: build build: @@ -14,8 +15,9 @@ build: install: $(INSTALL_DIR) $(DESTDIR)$(LIBEXEC_BIN) - CC="$(CC)" CFLAGS="$(PY_CFLAGS)" $(PYTHON) setup.py install \ - $(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force + CC="$(CC)" CFLAGS="$(PY_CFLAGS)" LDFLAGS="$(PY_LDFLAGS)" $(PYTHON) \ + setup.py install $(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" \ + --force $(INSTALL_PROG) scripts/convert-legacy-stream $(DESTDIR)$(LIBEXEC_BIN) $(INSTALL_PROG) scripts/verify-stream-v2 $(DESTDIR)$(LIBEXEC_BIN)